package com.example.mybatisplusdemo.service.impl;

import com.example.mybatisplusdemo.entity.TestUser;
import com.example.mybatisplusdemo.mapper.TestUserMapper;
import com.example.mybatisplusdemo.service.ITestUserService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author chenjl
 * @since 2022-06-24
 */
@Service
public class TestUserServiceImpl extends ServiceImpl<TestUserMapper, TestUser> implements ITestUserService {

    @Autowired
    TestUserMapper testUserMapper;

    /**
     * 根据名称得到用户对象
     *
     * @param username
     * @return
     */
    @Override
    public TestUser selectOneByUsername(String username) {
        return testUserMapper.selectOneByUsername(username);
    }
}
